package com.example.exercise;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class t {
    @RequestMapping("t1")
    public String t1(){
        return "打印t1" ;
    }
    @Value("${my-key.key}")
    private String key;

    @RequestMapping("t2")
    public String t2(String key){
        return "key:"+key;
    }

}
